package com.example.otto.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.otto.entity.Manager;
import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface ManagerMapper extends BaseMapper<Manager> {

//    @Select("select * from manager")
//    List<Manager> findAll();
//
//    @Insert("insert into manager(username, password, nickname, phone) values (#{username}, #{password}, #{nickname}, " +
//            "#{phone})")
//    int insert(Manager manager);
//
//
//    int update(Manager manager);
//
//    @Delete("delete from manager where id = #{id}")
//    int deleteById(@Param("id") Integer id);
//
//    @Select("select * from manager limit #{pageNum},#{pageSize}")
//    List<Manager> selectPage(Integer pageNum, Integer pageSize);
//
//    @Select("select count(*) from manager")
//    Integer selectTotal();
//
    @Select("select * from manager where username = #{username} and password = #{password}")
    Manager login(Manager manager);


}
